--[[1服务的入口文件2db操作]]----------------------------------------------------------- class---------------------------------------------------------local Service = class("Login")function Service:ctor(name)    self.handler = new("login.handler")    self:register()endfunction Service:register()    g.dispatch:register('start', handler(self, self.onStart))    g.dispatch:register('close', handler(self, self.onClose))endfunction Service:onStart()    print("onStart")    self.handler:onStart()    return trueendfunction Service:onClose()    print("onClose")    return trueendreturn Service